home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 …ember: Reference Library / Dev.CD Dec 97 RL.toast / What's New / Tool Chest / Testing & Debugging / Virtual User / Examples / Example External Tools / MathTool / VUAE.h < prev   
Encoding:
C/C++ Source or Header  |  1997-10-15  |  3.2 KB  |  86 lines  |  [TEXT/MPS ]

  1. /*
  2.  *    File:        VUAE.h
  3.  *
  4.  *    Contains:    This file is part of the Virtual User 2.0 external tool interface.
  5.  *
  6.  *    Written by:    Automation Systems, Apple Computer, Inc.
  7.  *
  8.  *    Copyright:    © 1992-1994 by Apple Computer, Inc., all rights reserved.
  9.  *
  10.  *    Change History (most recent first):
  11.  *
  12.  *         <5>    12/13/94    CMW        Add errAEThreadsNotPresent enum.
  13.  *         <4+>    12/12/94    SBR        Add errAEThreadsNotPresent enum.
  14.  *         <4>     12/3/94    CMW        Add kVUAEProtocolVersion parameter.
  15.  *         <3>      7/7/94    CMW        Make required service strings of type 'const char* const'.
  16.  *         <2>     1/13/94    CMW        Changed for Virtual User 2.1: kVUAESrvcResults = keyDirectObject
  17.  *         <9>    11/18/92    CMW        Add event id and wait amount parameter for dealing with
  18.  *                                    timeouts. Removed unused parameter consts for GetToolVers.
  19.  *         <7>    11/13/92    RV        
  20.  *        <6+>    11/13/92    RV        
  21.  *         <6>    11/12/92    CMW        Change occurances of "GetToolVers" to "GetToolVersion". Rename
  22.  *                                    all constants starting with kAEVU to start with kVUAE.
  23.  *         <5>     11/2/92    RV        Added Initialize string constant
  24.  *        <4+>     11/2/92    RV        Add "Initialize" string constant
  25.  *        <2+>     5/29/92    CMW        Change all occurances of "Command" to "Service" in the names of
  26.  *                                    all the constants and events.
  27.  *        <1+>     3/11/92    CMW        Update to reflect the changes to the External Tool calls for
  28.  *                                    2.0d3
  29.  *         <1>     2/20/92    JCC        
  30.  *         <4>     2/19/92    JCC        Finishing touches
  31.  *        <3+>     2/19/92    JCC        
  32.  *         <3>     2/13/92    JCC        Rewriting the pascal commands in C
  33.  *        <2+>     2/13/92    JCC        Rewriting the pascal commands in C
  34.  *         <2>     2/13/92    CMW        Add 'errAENoErr' to errors enumeration, convert #define'd
  35.  *                                    constants to 'const's, and fix the font.
  36.  *
  37.  *    To Do:
  38. */
  39.  
  40.  
  41. #ifndef __VUAE__
  42. #define __VUAE__
  43.  
  44. #ifndef __TYPES__
  45. #include <Types.h>
  46. #endif
  47.  
  48. #ifndef __APPLEEVENTS__
  49. #include <AppleEvents.h>
  50. #endif
  51.  
  52. /* Standard constants used for communicating with VU External Tools */
  53. const long kVUAETool            = 'v.u.';    /* event class for V.U. 2.0 external tool interface */
  54. const long kVUAESendService        = 'extc';    /* event id for SendToolService */
  55. const long kVUAEWaitLonger        = 'extw';    /* event id for WaitLongerForService */
  56.  
  57. const long kVUAESrvcName        = keyDirectObject;    /* Service name for external tool Service */
  58. const long kVUAESrvcParameters    = 'extp';
  59. const long kVUAESrvcResults        = keyDirectObject;
  60. const long kVUAESrvcTarget        = 'targ';
  61. const long kVUAEWaitAmount        = 'xtwa';
  62. const long kVUAEProtocolVersion    = 'xtpv';    /* NEW FOR 2.1 */
  63.  
  64. const long kVUAEOldSrvcResults    = 'extr';    /* Do not use for future development: */
  65.                                             /* (this is not AppleScript friendly) */
  66.  
  67. /* Errors specific to the VU External Tool Interface*/
  68. enum VUAEErrors
  69. {
  70.     errAENoErr = 0,
  71.     errAENeverReturnThisErrorCode = 1,    /* Never EVER return this number as an error code!!! */
  72.     errAEValueTooSmall = 2,
  73.     errAEWrongParameters = 3,            /* incorrect parameters passed to external tool */
  74.     errAEUnknownService = 4,
  75.     errAEThreadsNotPresent = 5            /* ThreadedService called, no threads present */
  76. };
  77.  
  78. const char* const    kVUAEInitialize        = "Initialize";
  79. const char* const    kVUAECancelService    = "Cancel";
  80. const char* const    kVUAEGetToolVersion    = "GetToolVersion";
  81. const char* const    kVUAEGetServiceList    = "GetToolServices";
  82. const char* const    kVUAEHasService        = "ServiceSupported";
  83. const char* const    kVUAEQuitService    = "Quit";
  84.  
  85. #endif
  86.